package com.zy.propertysource.demo.config;

import org.springframework.boot.SpringApplication;
import org.springframework.boot.context.config.ConfigFileApplicationListener;
import org.springframework.core.env.ConfigurableEnvironment;

public class MyConfigFileApplicationListener extends ConfigFileApplicationListener {

    @Override
    public void postProcessEnvironment(ConfigurableEnvironment environment,
                                       SpringApplication application) {
        IpValuePropertySource.addToEnvironment(environment);
        super.postProcessEnvironment(environment, application);
    }
}
